package in.muton.edushare.modules.navigatedWizard;

import org.apache.wicket.markup.html.WebPage;
import org.apache.wicket.markup.html.panel.Panel;

public abstract class AbstractNavigationTab extends Panel {

	private static final long serialVersionUID = 6746990201363669464L;
	private String tabTitle;
	private WebPage containingPage;
	private NavigatedWizardPanel navPanel;
	
	public AbstractNavigationTab(String tabTitle, WebPage wp) {
		super("AbstractNavigationTab");
		this.tabTitle = tabTitle;
		this.containingPage = wp;
	}
	
	public abstract void save();

	public String getTabTitle() {
		return tabTitle;
	}

	public WebPage getContainingPage() {
		return this.containingPage;
	}

	public void setNavigatedWizardPanel(NavigatedWizardPanel navigatedWizardPanel) {
		this.navPanel = navigatedWizardPanel;
	}
	
	public void back(){
		navPanel.previous();
	}
	
	public void skip(){
		navPanel.skip();
	}
	
	public void next(){
		navPanel.next();
	}
}
